#include <stdint.h>
#include "mylist.h"

typedef int (*hash_fun)(uint8_t *key);

typedef struct {
    uint8_t *key;
    void *value;
} myhentry;

typedef struct {
    mylist **table;
    int table_len;
    int entry_size;
    hash_fun hfun;
} myhashtable;

myhashtable *myhashtable_create(int tlen, hash_fun hf);
int myhashtable_put(myhashtable *ht, uint8_t *key, void *value);
void *myhashtable_get(myhashtable *ht, uint8_t *key);
void *myhashtable_delete(myhashtable *ht, uint8_t *key);
